package com.zhz.thymeleafdemo.service.impl;

import com.zhz.thymeleafdemo.dao.UserMapper;
import com.zhz.thymeleafdemo.pojo.User;
import com.zhz.thymeleafdemo.service.UserService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class UserServiceImpl implements UserService {

    @Resource
    private UserMapper userMapper;

    @Override
    public User getUserByName(String name) {
        return userMapper.getUserByName(name);
    }

    @Override
    public List<User> queryUserList() {
        return userMapper.queryUserList();
    }

    @Override
    public User updateUser(User user) {
        return userMapper.updateUser(user);
    }
}
